Make non-ASCII strings in ui files work
authorMatthias Clasen <mclasen@redhat.com>
Fri, 3 Oct 2014 01:28:43 +0000 (21:28 -0400)
committerMatthias Clasen <mclasen@redhat.com>
Fri, 3 Oct 2014 01:28:43 +0000 (21:28 -0400)
Our extractor tool was not calling setlocale(), thus it only
produced output in the C locale, ie ASCII. Oops.

util/extract-strings.c

index 183b99a4c420285835c3d9df4175c3308596dd27..5dd379e6d4527a7c9474745683583cabdd10922a 100644 (file)
@@ -15,6 +15,7 @@
  * License along with this library. If not, see <http://www.gnu.org/licenses/>.
  */
 
+#include <locale.h>
 #include <glib.h>
 
 typedef struct {
@@ -143,6 +144,8 @@ main (int argc, char *argv[])
   GMarkupParseContext *context;
   ParserData data;
 
+  setlocale (LC_ALL, "");
+
   if (argc < 2)
     {
       g_printerr ("Expect a filename\n");